#region Using
using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;
#endregion Using

namespace CY.GFive.Core.Business
{
	public class TeachingPlan : Business.BusinessBase<TeachingPlan, int>
	{
		#region Fields and Properties

		private int crsNumPerTerm = 0;
		/// <summary>
		/// 
		/// </summary>
		public int CrsNumPerTerm
		{
			get { return crsNumPerTerm; }
			set
			{
				if (value != crsNumPerTerm)
				{
					MarkChanged("CrsNumPerTerm");
					crsNumPerTerm = value;
				}
			}
		}

		private Boolean isTheory = default(Boolean);
		/// <summary>
		/// 
		/// </summary>
		public Boolean IsTheory
		{
			get { return isTheory; }
			set
			{
				if (value != isTheory)
				{
					MarkChanged("IsTheory");
					isTheory = value;
				}
			}
		}

		private String courseCate = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String CourseCate
		{
			get { return courseCate; }
			set
			{
				if (value != courseCate)
				{
					MarkChanged("CourseCate");
					courseCate = value;
				}
			}
		}

		private int term = 0;
		/// <summary>
		/// 
		/// </summary>
		public int Term
		{
			get { return term; }
			set
			{
				if (value != term)
				{
					MarkChanged("Term");
					term = value;
				}
			}
		}

		private String courseCode = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String CourseCode
		{
			get { return courseCode; }
			set
			{
				if (value != courseCode)
				{
					MarkChanged("CourseCode");
					courseCode = value;
				}
			}
		}

		private String proCode = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String ProCode
		{
			get { return proCode; }
			set
			{
				if (value != proCode)
				{
					MarkChanged("ProCode");
					proCode = value;
				}
			}
		}

		#endregion Fields and Properties

		#region Constructors

		public TeachingPlan()
		{
		}

		#endregion Constructors

		#region Base overrides

		protected override void ValidationRules()
		{
		}

		protected override TeachingPlan DataSelect(int id)
		{
			return Services.DALService.TeachingPlanService.Select(id);
		}

		protected override void DataUpdate()
		{
			Services.DALService.TeachingPlanService.Update(this);
		}

		protected override void DataInsert()
		{
			Services.DALService.TeachingPlanService.Insert(this);
		}

		protected override void DataDelete()
		{
			Services.DALService.TeachingPlanService.Delete(this);
		}

		#endregion Base overrides
	}
}
